<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
<script>
    //封装自己的Math对象 最小值和最大值的封装
    var myMath = {
        PI:'3.141592653',
        max:function(){
            var max = arguments[0];
            for(i=1;i<arguments.length;i++ ){

                if(max<arguments[i]){
                    max = arguments[i];

                }
            }
            return max;
        },
        mix:function(){
            var mix = arguments[0];
            debugger
            for(i=1;i<arguments.length;i++ ){
                if(mix>arguments[i]){
                    debugger
                    mix = arguments[i];
                }
            }
            return mix;
        }
    };

    console.log(myMath.max(23,54,88,98,78));
    console.log(myMath.mix(23,54,88,98,78));


</script>
</body>
</html>